﻿using System;
using System.Collections.Generic;
using System.Threading;

namespace Kobets.Automation.Chimera.Common.Contracts
{
    public interface ICommand
    {
        event EventHandler<EventArgs<Guid>> CommandComplete;
        event EventHandler<EventArgs<KeyValuePair<Guid, Exception>>> CommandFailed;
        event EventHandler<EventArgs<Guid>> CommandInProgress;
        void Execute(string content, Guid stepId, CancellationToken token);
        void Abort();
        string SerializeContent(dynamic content);
        dynamic DeserializeContent(string content);
    }
}
